#include <iostream>
#include "pointlist.h"
using namespace std;
int main(int argc, char** argv) {
	PointList polygon;
	Point vertex;
	cout<<"Enter the polygon's vertices (end with eof):";
	while(cin>>vertex.x>>vertex.y&&!polygon.isFull())
		polygon.append(vertex);
	if(!polygon.isEmpty())
	{
		polygon.gotoBeginning();
		do
		{
			vertex=polygon.getCursor();
			cout<<"("<<vertex.x<<","<<vertex.y<<")"<<endl;
		}
		while(polygon.gotoNext());
	}
	return 0;
}
